using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

namespace MMFrameworkDesign.Example
{
    public static class GameStartEvent
    {
        private static Action mOnEventTrigger;
        
        // 注册事件
        public static void Registry(Action onEvent)
        {
            mOnEventTrigger += onEvent;
        }
        
        // 注销事件
        public static void UnRegistry(Action onEvent)
        {
            mOnEventTrigger -= onEvent;
        }
        
        // 触发事件
        public static void Trigger()
        {
            mOnEventTrigger?.Invoke();
        }
    }
}

